#include "apue.h"
#include <stdio.h>
#include <fcntl.h>

int main() {
    char * path= "/dev/fd/1";
    int fd;

    unlink(path);
    if ((fd= creat(path, FILE_MODE)) < 0)
        err_sys("open %s failed", path);

    write(fd, "Hello word!", 11);

    return 0;
}
